package com.example.zwgt.yrfk.retroft;

import com.example.zwgt.yrfk.base.mvpbase.baseImpl.BaseBean;
import com.example.zwgt.yrfk.bean.GuestInfo;
import com.example.zwgt.yrfk.bean.LoginResponseInfo;
import com.example.zwgt.yrfk.bean.LoginUser;
import com.example.zwgt.yrfk.bean.TestBean;

import java.util.HashMap;

import io.reactivex.Observable;
import retrofit2.http.Body;
import retrofit2.http.GET;
import retrofit2.http.HeaderMap;
import retrofit2.http.POST;
import retrofit2.http.Path;
import retrofit2.http.Query;

public interface RetrofitService {

    String BASE_URL = "http://47.98.229.83/index.php/index/";
    //String BASE_URL = "http:\\/\\/api.zwgt.com";

    /**
     * 登录接口
     *
     * @return
     */
    @GET("login")
    Observable<BaseBean<TestBean>> login(@Query("phone") String phone,
                                        @Query("password")String password);

/*    @POST("/app-login")
    Observable<LoginResponseInfo> login(@HeaderMap HashMap<String, String> map,
                                                  @Body LoginUser lu);*/

    /**
     * 查询所有列表
     */
    @GET("/{path}")
    Observable<BaseBean<GuestInfo>> getGuestList(@Path("path") String path,
                                                 @HeaderMap HashMap<String, String> map);

}
